{NeoBook Function}
Version=5.80
Language=NeoBook
Comment=hpwPlusMemo - Get the whole current line which pointer is somewhere on it.
Param=[%1]|Text|PlusMemo rectangle object name
Param=[%2]|Variable|Variable to store line data
{End}
Math "[[%1]_CurLine]+1" "0" "[NOYZEN_current_line_number]"
Math "[[%1]_SelStart]-[[%1]_CurLinePos]" "0" "[NOYZEN_Start_of_Line]"

If "[NOYZEN_current_line_number]" "=" "[[%1]_LineCount]"
    hpwPlusMemoGetText "[%1]" "[NOYZEN_Start_of_Line]" "[[%1]_ByteCount]" "[%2]"
Else
    hpwPlusMemoGetText "[%1]" "[NOYZEN_Start_of_Line]" "[[%1]_ByteCount]" "[NOYZEN_look_for_line]"
    SearchStr "[#13]" "[NOYZEN_look_for_line]" "[NOYZEN_End_of_Line]" ""
    hpwPlusMemoGetText "[%1]" "[NOYZEN_Start_of_Line]" "[NOYZEN_End_of_Line]" "[%2]"
EndIf

ClearVariables "[NOYZEN_current_line_number],[NOYZEN_Start_of_Line],[NOYZEN_look_for_line],[NOYZEN_End_of_Line]"
